<script setup>
import {ref} from "vue";

const form=ref({
  name: "admin",
  password: "123456",
})
const login=()=>{
  console.log(form.value)
}
</script>

<template>
  <el-form label-position="top" label-width="100px">
    <el-form-item label="姓名" >
      <el-input placeholder="请输入姓名" v-model="form.name"></el-input>
    </el-form-item>
    <el-form-item label="密码" >
      <el-input type="password" placeholder="请输入姓名" v-model="form.password"></el-input>
    </el-form-item>
    <el-button @click="login">登录</el-button>
  </el-form>
</template>

<style scoped>

</style>